package cn.tedu.qxhouserent.house.mapper;

import cn.tedu.qxhouserent.house.pojo.entity.User;
import cn.tedu.qxhouserent.house.pojo.vo.UserListItemVO;
import cn.tedu.qxhouserent.house.pojo.vo.UserStandardVO;
import com.baomidou.mybatisplus.core.conditions.Wrapper;
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import org.apache.ibatis.annotations.Param;
import org.springframework.cache.annotation.CacheEvict;
import org.springframework.stereotype.Repository;

import java.util.List;

@Repository
public interface UserMapper extends BaseMapper<User> {
    @CacheEvict
    Integer selectCount(@Param("ew") Wrapper<User> queryWrapper);

    List<UserListItemVO> list();

    UserStandardVO getStandardById(Long id);

    UserStandardVO getStandardByUsername(String username);
}
